package com.berchen.test;

import java.io.IOException;
import java.io.InputStream;
import java.util.Properties;

public class PropertiesDemo {
    public static void main(String[] args) throws IOException {
        InputStream in = PropertiesDemo.class.getClassLoader().getResourceAsStream("test.properties");
        Properties properties=new Properties();

        properties.load(in);
        String name = properties.getProperty("name");
        System.out.println(name);
    }
}
